<?php
namespace BoojasrMVC\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Class User
 * @package BoojasrFramework\Entity
 * @ORM\Table(name="user")
 * @ORM\Entity(repositoryClass="BoojasrMVC\Repository\UserRepository")
 */
class User
{
    /**
     * @ORM\Id()
     * @ORM\GeneratedValue(strategy="AUTO")
     * @ORM\Column(type="integer")
     */
    private $id;

    /**
     * @ORM\Column(type="string", length=20, unique=true,options={"comment":"用户登录名（手机号码）"})
     */
    private $username;

    /**
     * @return mixed
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * @param mixed $username
     */
    public function setUsername($username): self
    {
        $this->username = $username;

        return $this;
    }

    /**
     * @return mixed
     */
    public function getUsername()
    {
        return $this->username;
    }
}